package com.dykj.fireFighting.server.base.video.mapper;


import com.dykj.fireFighting.api.base.video.entity.VideoDevice;
import com.dykj.fireFighting.common.core.mapper.SuperMapper;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;

/**
 * @Description 摄像头设备中间表
 * @Author JacksonTu
 * @Date  2021-07-23 13:34:10
 */
public interface VideoDeviceMapper extends SuperMapper<VideoDevice> {

    @Select("select device_id from video_device where video_id=#{videoId} and type=#{type}" )
    List<String> getByVideoId(@Param("videoId") String videoId,@Param("type") Integer type);

    @Delete("DELETE FROM video_device where video_id=#{videoId}")
    int delByVideoId(@Param("videoId") String videoId);

}
